package cn.jilian.common.service.sms;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
import org.springframework.stereotype.Service;

import cn.jilian.common.service.SMSService;

@Service
@ConditionalOnProperty(prefix="sms.platform",name="provider",havingValue="mock")
public class MockSmsService implements SMSService {

	private final Logger logger=LoggerFactory.getLogger(getClass());
	
	@Override
	public int sendSms(String tel, String content) {
		logger.info("send sms[{}] by mobile[{}]",content,tel);
		return 0;
	}

	@Override
	public int sendSmsCode(String tel, String templateId, String code) {
		// TODO Auto-generated method stub
		return 0;
	}

}
